﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.ComponentModel;

namespace Real.Silverlight.TestApp
{
    public class DataGridSubModel: INotifyPropertyChanged
    {
        private string _item1;
        /// <summary>
        /// The PropertyName property
        /// </summary>
        public string Item1
        {
            get
            {
                return _item1;
            }
            set
            {
                _item1 = value;
                RaisePropertyChanged("Item1");
            }
        }

        private string _item2;
        /// <summary>
        /// The PropertyName property
        /// </summary>
        public string Item2
        {
            get
            {
                return _item2;
            }
            set
            {
                _item2 = value;
                RaisePropertyChanged("Item2");
            }
        }


        private DataGridMainModel _MainModel;
        /// <summary>
        /// The MainModel property
        /// </summary>
        public DataGridMainModel MainModel
        {
            get
            {
                return _MainModel;
            }
            set
            {
                _MainModel = value;
                RaisePropertyChanged("MainModel");
            }
        }


        public event PropertyChangedEventHandler PropertyChanged;

        protected void RaisePropertyChanged(string prop)
        {
            if (PropertyChanged != null) PropertyChanged(this, new PropertyChangedEventArgs(prop));
        }
    }
}
